{include file="static/appm/tpl_header.html" /}
<body xmlns="http://www.w3.org/1999/html">
<div class="weui-tab container">
    <div class="weui-flex bg-faded aurora-edit-head">
        <div class="weui-flex__item">
            <div class="placeholder">
                <a href="{:urlBuild('!.faccount')}">财务账单</a> / 明细
            </div>
        </div>
    </div>
    {// @todo 新版的 weui weui-panel 无法显示}
    <div class="weui-panel weui-panel_access" style="overflow: visible;">
        <div class="weui-panel__hd">总账概要</div>
        <div class="weui-panel__bd">
            <div class="weui-media-box weui-media-box_text">
                <h4 class="weui-media-box__title">{$sum.name}</h4>
                <h4 class="weui-media-box__title">
                    <i class="fa {if condition="$sum.type eq 'IN'"}fa-plus-circle text-success{else}fa-minus-circle text-info{/if}"></i>
                    {$sum.money}
                </h4>
                <div style="padding-left: 10px;color: #9b9b9b;">
                    {$sum.descrip}
                </div>
                <ul class="weui-media-box__info">
                    <li class="weui-media-box__info__meta">{$sum.mtime}</li>
                    <li class="weui-media-box__info__meta weui-media-box__info__meta_extra">{$sum.city}</li>
                    <li class="weui-media-box__info__meta">
                        <a href="javascript:;" class="text-success" id="sync-set"><i class="fa fa-recycle"></i> 明细同步</a>
                    </li>
                </ul>
            </div>
        </div>
        <div class="weui-flex aurora-border"></div>
        <div class="weui-flex">
            <div class="weui-flex__item" style="margin-left: 15px;font-style: italic;">
                合计：<span id="sum_col">{$sum.detailAll|default="0"}</span> ￥
            </div>
            <div class="weui-flex__item">
                <a href="javascript:;" id="add_detail_lnk" style="float: right;margin-right: 10px;font-size: 1.02em;"><i class="fa fa-exchange text-info"></i></a>
            </div>
        </div>
        <div class="weui-tab">
            <div class="weui-tab__panel" id="list">
                <div class="weui-cells">
                    {$list}
                </div>
            </div>
            <!--编辑页面-->
            <div class="weui-tab__panel aurora-hidden" id="edit">
                <div class="weui-cells weui-cells_form">
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="name_ipter" class="weui-label text-danger">*名称</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="name_ipter" type="text" name="name" emptytips="请设置名称" required="">
                        </div>
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="money_ipter" class="weui-label text-danger">*金额</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="money_ipter" type="number" name="money" emptytips="请设置金额" required="">
                        </div>
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="discount_ipter" class="weui-label">折扣</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="discount_ipter" type="number" name="discount">
                        </div>
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="part_ipter" class="weui-label text-danger">*份数</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="part_ipter" type="number" name="part" emptytips="请设置份数" required="" value="1">
                        </div>
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="amount_ipter" class="weui-label">数量</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="amount_ipter" type="number" name="amount">
                        </div>
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="unit_ipter" class="weui-label">单位</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="unit_ipter" type="text" name="unit" value="kg">
                        </div>
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label for="remark_ipter" class="weui-label">备注</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" id="remark_ipter" type="text" name="remark">
                        </div>
                    </div>
                </div>
                <div class="weui-flex aurora-border"></div>
                <div class="weui-btn-area">
                    <a class="weui-btn weui-btn_primary" href="javascript:" id="edit_submit_lnk">保存</a>
                </div>
            </div>
        </div>
    </div>
</div>
</body>
</html>